<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title></title>
        <link rel="stylesheet" type="text/css" href="../css/reset.css"/>
        <link rel="stylesheet" type="text/css" href="../css/qxlb.css"/>
    </head>
    <body>
        
        
        <header class="head">
            <div class="left">
                <img src="../imgs/fhjt.png"/>
            </div>
            <div class="center">抢修任务列表</div>
            <div class="right"></div>
        </header>
        
        <section class="sec">
            <div class="time">
                <ul>
                    <li>
                        <select>
                            <option>2013-09-01</option>
                        </select>
                    </li>
                    <li>
                        <select>
                            <option>保修中</option>
                        </select>
                    </li>
                    <li class="cha">
                        <div>查询</div>
                    </li>
                </ul>
            </div>
            
            <div class="zhong">
                <div class="riqi">
                    <span>填报日期</span>
                    <p>医院</p>
                    <i class="in">单据状态</i>
                </div>
            </div>
            
            <div class="lis">
                <ul class="liebiao">

                </ul>
            </div>
            
        </section>
        
        <footer class="fot">
            <div class="foot">
                <p>新建抢修信息</p>
            </div>
        </footer>
        
        
        <script src="../js/flexible.debug.js"></script>
        <script src="../js/flexible_css.debug.js"></script>
        <script src="../js/jquery-1.12.4.min.js"></script>
        <script src="../js/artTemplate.js"></script>
        
        <script type="text/html" id="moban">
        
            {{each list as e}}
                <li>
                    <span>{{e.time}}</span>
                    <p>{{e.name}}</p>
                    <i>{{e.xiu}}</i>
                    <div><img src="../img/jiantou.jpg"/></div>
                </li>
            {{/each}}
            
        </script>
        
        <script>
            
            $(function(){
                
                function lib(star, end){
                    
                    $.ajax({
                        type: "get",
                        dataType: "json",
                        url: "../json/qxlb.json",
                        success: function(data, v){
                            //console.log(data, v);
                            data = data.slice(star, end);
                            //if(data.length < 1) $(".cha").hide();
                            var str = template("moban", {list: data});
                            //console.log(str);
                            $(".liebiao").append($(str));
                        }
                    })
                }
                
                var srt = 0, str = 1;
                
                lib(srt, str);
                
                $(".cha").click(function(){
                    //console.log(str,srt)
                    srt += 1;
                    str += 1;
                    lib(srt, str);
                })
                
            })
            
            $(".head .left").on("click", function(){
                location.href = "qiangxiujieguobaogao.html";
            });
            
            $(".lis .liebiao").on("click", function(){
                location.href = "shebeiweihu.html";
            })
            
        </script>
        
    </body>
</html>